<?php
@session_start();
if (!isset($_SESSION["TimeExpire"])) {
    $_SESSION["TimeExpire"] = time();
} else
if (time() - $_SESSION["TimeExpire"] > 600) {
    unset($_SESSION["Username"]);
    unset($_SESSION["TimeExpire"]);
    header("location:../views/Admin_login.php?logout=TRUE");
}
?>
<div class="logo">
    <a href="../views/index.php"><span>LOGO</span></a>
</div>

<!-- mainNav -->
<ul id="mainNav">
    <li><a href="../views/AccountManager.php">Tài khoản</a></li>
    <li><a href="../views/ProductManager.php">Sản phẩm</a></li>
    <li><a href="../views/SectionManager.php">Section</a></li>
    <li><a href="../views/CategoryManager.php">Category</a></li>
    <li><a href="../views/GroupManager.php">Nhóm người dùng</a></li>
    <li><a href="../views/OrderManager.php">Đơn đặt hàng</a></li>
    <!--	<li><a href="">Banner - Footer</a></li>-->
    <li><div style="padding:10px 0px 0px 20px;width:166px;text-align: center;">
            <?php if (isset($_SESSION["Username"])):echo"Xin Chào: <b style='color:#5E0000;'>" . $_SESSION["Username"] . "</b>";
            endif ?>
        </div></li>
    <li class="logout"><a href="../views/Admin_login.php?logout=TRUE">Đăng Xuất</a></li>
</ul>

<div class="clear"></div>
<div style="float:right; margin-bottom:10px;">
    <a href="../views/UpdateAccount.php?acc=<?php echo $_SESSION["Username"] ?>">Thay đổi thông tin tài khoản cá nhân</a>
</div>
<!-- // #end mainNav -->
<div class="clear">
</div>

